<?php
    if(isset($_GET['id'])&&(is_numeric($_GET['id']))){
        $id = $_GET['id'];
?>
            <script type="text/javascript" src="./plugin/validation/jquery.js"></script>
            <script type="text/javascript" src="./plugin/validation/jquery.validate.js"></script>
            <div id="add-comment-box">
                <span class="comment-title">Commenta questo articolo</span><br /><br />
                <form id="comment-form" method="post" action="./includes/action_comment.php?id=<?=$id;?>">
                    <!-- Vecchio stile delle label: span comment-data -->
                    <input type="text" name="com_nome" placeholder="Nome" class="comment-input" maxlenght="15" required /><br />
                    <input type="email" name="com_email" placeholder="Indirizzo e-mail" class="comment-input" required /><span class="commment-note"> (Non verrà pubblicato)</span><br />
    
                    <img id="captcha" src="./plugin/securimage/securimage_show.php" alt="CAPTCHA Image" style="border: 1px solid #3C8CBD; margin-bottom:9px;" height="40" width="160" /><br>
                    <input type="text" name="captcha_code" placeholder="Codice di conferma" maxlength="6" class="comment-input" required /> 
                    (<a href="#" onclick="document.getElementById('captcha').src = './plugin/securimage/securimage_show.php?' + Math.random(); return false">Carica un nuovo codice</a>)
    
                    <textarea class="comment-text" name="com_text" required /></textarea><br />
                    <span class="comment-button"><input type="submit" value="Pubblica commento" name="submit" class="comment-button"></span>
                </form>
<?php
    }
?>
			</div><!-- /main -->